/*
                  Food Class Implementation
*/
#include "Food.h"

Food::Food()
{

}

Food::~Food()
{

}

void Food::Draw(SDL_Surface *surface)
{
    if (Sprite == NULL) { return; }

    SDL_Rect dstRect;

    dstRect.x = (int)Position.x;
    dstRect.y = (int)Position.y;

    SDL_BlitSurface(Sprite, NULL, surface, &dstRect);
}

int Food::getType()
{
    return iType;
}

void Food::setType(const int& iNewType)
{
    iType = iNewType;

    Sprite = FoodInfo::getTypeSprite(iType);
}

Point Food::getPosition()
{
    return Position;
}

void Food::setPosition(const Point& NewPosition)
{
    Position = NewPosition;
}
